#!/usr/bin/env bash

if [ ! -f install ]; then
    echo 'install must be run within its container folder' 1>&2
    exit 1
fi

CURDIR=`pwd`
OLDGOPATH="$GOPATH"
export GOPATH="$CURDIR"

gofmt -w src

export GOOS=linux

go get github.com/fasthttp-contrib/websocket
go install webserver

export GOPATH="$OLDGOPATH"

echo 'finished'
